<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
	<th:block th:include="include :: header('修改供应商')" />
</head>
<body class="white-bg">
	<div class="wrapper wrapper-content animated fadeInRight ibox-content">
		<form class="form-horizontal m" id="form-supplier-edit" th:object="${supplier}">
			<div class="form-group">
				<label class="col-sm-3 control-label ">供应商名称：</label>
				<div class="col-sm-8">
				<input class="form-control" type="hidden" name="supplierId" th:field="*{supplierId}" >
					<input class="form-control" type="text" name="supplierName" th:field="*{supplierName}"  required>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label ">供应商负责人：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="supplierPerson"  th:field="*{supplierPerson}"  required>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">供应商电话：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text"   name="supplierTel"  th:field="*{supplierTel}"  required>
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">供应商邮箱：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text"  th:field="*{supplierEmail}"  name="supplierEmail">
				</div>
			</div>
			<div class="form-group">
				<label class="col-sm-3 control-label">供应商地址：</label>
				<div class="col-sm-8">
					<input class="form-control" type="text" name="supplierAddress" th:field="*{supplierAddress}">
				</div>
			</div>			
		</form>
	</div>
	<th:block th:include="include :: footer" />
	<script type="text/javascript">
		var prefix = ctx + "wms/supplier";	
		$("#form-supplier-edit").validate({
			rules:{
				dictSort:{
					digits:true
				},
			},
			focusCleanup: true
		});
		
		function submitHandler() {
	        if ($.validate.form()) {
	        	$.operate.save(prefix + "/edit", $('#form-supplier-edit').serialize());
	        }
	    }
	</script>
</body>
</html>
